<?php
namespace app\common\validate;

use think\Validate;

class Product extends Validate{

    protected $rule = [
        'title' => 'require',
        'number' => 'require',
        'factory_id' => 'require',
        'market_price' => 'require',
        'sell_price'  =>  'require',
        'salary'      =>  'require',
    ];

    protected $message = [
        'title.require' => '产品名称必须填写',
        'number.require' => '产品编号必须填写',
        'factory_id.require' => '必须选择厂家',
        'market_price.require' =>'请填写市场价',
        'sell_price.require' => '请填写团购价',
        'salary.require'    => '请填写佣金数额',
    ];

}